projects
/
gtk4.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
afdde92
)
[broadway] Cancel key events after seeing them
author
Alexander Larsson
<alexl@redhat.com>
Tue, 12 Apr 2011 11:38:04 +0000
(13:38 +0200)
committer
Alexander Larsson
<alexl@redhat.com>
Tue, 12 Apr 2011 11:38:04 +0000
(13:38 +0200)
gdk/broadway/broadway.js
patch
|
blob
|
history
diff --git
a/gdk/broadway/broadway.js
b/gdk/broadway/broadway.js
index 82c7ac42f9d74d9d89062fff55d2ef7649f046d9..f8ad88ea71456fef82622185a838ff99d76083d3 100644
(file)
--- a/
gdk/broadway/broadway.js
+++ b/
gdk/broadway/broadway.js
@@
-1098,21
+1098,23
@@
var lastKeyDown = 0;
function onKeyDown (ev) {
updateForEvent(ev);
if (localGrab)
- return;
+ return
cancelEvent(ev)
;
var keyCode = ev.keyCode;
if (keyCode != lastKeyDown) {
sendInput ("k", [keyCode]);
lastKeyDown = keyCode;
}
+ return cancelEvent(ev);
}
function onKeyUp (ev) {
updateForEvent(ev);
if (localGrab)
- return;
+ return
cancelEvent(ev)
;
var keyCode = ev.keyCode;
sendInput ("K", [keyCode]);
lastKeyDown = 0;
+ return cancelEvent(ev);
}
function cancelEvent(ev)